﻿<catel:DataWindow x:Class="Catel.Articles._02___WPF_controls.UI.Windows.PersonWindow"
                  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                  xmlns:ViewModels="clr-namespace:Catel.Articles._02___WPF_controls.UI.ViewModels"
                  xmlns:catel="http://catel.codeplex.com"
                  x:TypeArguments="ViewModels:PersonViewModel" MinWidth="400" MaxWidth="400">
    <!-- Resources -->
    
    <!-- Content -->
    <Grid>
        <!-- Row definitions -->
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        
        <!-- Column definitions -->
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        
        <!-- First name -->
        <Label Grid.Row="0" Grid.Column="1" Content="First name:" />
        <TextBox Grid.Row="0" Grid.Column="1" Text="{Binding FirstName, NotifyOnValidationError=True, ValidatesOnDataErrors=True}" />

        <!-- Middle name -->
        <Label Grid.Row="1" Grid.Column="1" Content="Middle name:" />
        <TextBox Grid.Row="1" Grid.Column="1" Text="{Binding MiddleName, NotifyOnValidationError=True, ValidatesOnDataErrors=True}" />

        <!-- Last name -->
        <Label Grid.Row="2" Grid.Column="1" Content="Last name:" />
        <TextBox Grid.Row="2" Grid.Column="1" Text="{Binding LastName, NotifyOnValidationError=True, ValidatesOnDataErrors=True}" />
    </Grid>
</catel:DataWindow>
